public class Rectangle {
	
		
	private Point p1, p2;
	
	/*
	 * The Rectangle has two Point objects (p1 and p2), which themselves 
	 * each have 2 coordinates (xCoord,yCoord)
	 */
	Rectangle(Point p1, Point p2) {
		this.p1 = p1;
		this.p2 = p2;
	}
	
	public Double getArea() {
		return Math.abs((p2.xCoord - p1.xCoord) * (p2.yCoord - p1.yCoord));
	}
	
	public Double getDiagonal() {
		return Math.sqrt(Math.pow((p2.xCoord - p1.xCoord), 2) + Math.pow((p2.yCoord - p1.yCoord), 2));
	}
}

